package com.ykc.bean;

import java.util.HashMap;
import java.util.Map;

/**
 * @author Ykc
 * @date 2021年05月25日 15:11
 * @description
 */
public class View {
    //视图路径
    private String path;
    //模型数据
    private Map<String,Object> model;

    public View(String path){
        this.path=path;
        this.model=new HashMap<>();
    }

    public View addModel(String path,Object value){
        model.put(path,value);
        return this;
    }

    public String getPath() {
        return path;
    }

    public Map<String, Object> getModel() {
        return model;
    }
}
